<!DOCTYPE html>
<html>
<head>
    <meta charset="UTF-8">
    <title> {$action} | {:get_opinion('title')}</title>

    <include file="Public:head"/>

</head>
<body class="skin-black">

{:W('Common/header')}

<div class="wrapper row-offcanvas row-offcanvas-left">
    {:W('Common/sideMenu')}


    <!-- Right side column. Contains the navbar and content of the page -->
    <aside class="right-side">
        <!-- Content Header (Page header) -->


        <section class="content-header">
            <h1>
                {$action}
                <small>{$Think.config.title}</small>
            </h1>
            <ol class="breadcrumb">
                <li><a href="{$module_url}"><i class="fa fa-dashboard"></i> {$module}</a></li>
                <li class="active">{$action}</li>
            </ol>
        </section>

        <!-- Main content -->
        <section class="content">

            <div class="row">
                <div class="col-md-12">
                    <div class="box box-warning">
                        <div class="box-header">
                            <h3 class="box-title">{$action}</h3>
                        </div>
                        <!-- /.box-header -->
                        <div class="box-body">                    <!-- BEGIN EXAMPLE TABLE PORTLET-->


                            <div class="portlet-body">
                                <div class="row margin">
                                    <div class="btn-group">
                                        <a href="{:U('Weixin/User/updatenew')}">
                                            <button type="submit" class="btn bg-green" name="postAdd" value='1'>
                                                <i class="icon-plus"></i>更新用户信息
                                            </button>
                                        </a>

                                    </div>

                                    <div class="btn-group">
                                        <a href="{:U('Weixin/User/updateall')}">
                                            <button class="btn bg-purple">
                                                <i class="icon-plus"></i>同步用户
                                            </button>
                                        </a>

                                    </div>

                                </div>
                                <table class="table table-striped table-bordered table-hover"
                                       id="sample_1">
                                    <thead>
                                    <tr>
                                        <th style="width:130px;">关注时间</th>

                                        <th style="width:75px;">昵称</th>
                                        <th>地区</th>
                                        <th style="width:75px;">头像</th>
                                        <th style="width: 8px;">openid</th>

                                        <th style="width:200px;">操作</th>

                                    </tr>
                                    </thead>
                                    <tbody>
                                    <foreach name="user_list" item="v">
                                        <tr class="odd gradeX">
                                            <td>{:date ('Y-m-d H:i',$v['subscribe_time']) }</td>

                                            <td>{$v.nickname}</td>
                                            <td>{$v.country}-{$v.province}-{$v.city}</td>
                                            <td><img src="{$v.headimgurl}"></td>
                                            <td> {$v.openid}</td>

                                            <td>

                                                <a class="btn green"
                                                   href="{:U('Weixin/User/detail',array('openid'=>$v['openid']))}">查看用户</a>

                                                <a class="btn blue"
                                                   href="{:U('Weixin/User/chat',array('openid'=>$v['openid']))}">查看对话</a>

                                                <a class="btn"
                                                   href="{:U('Weixin/Message/send',array('openid'=>$v['openid']))}">发送消息</a>

                                            </td>


                                        </tr>
                                    </foreach>
                                    </tbody>
                                </table>

                            </div>
                            <!-- END EXAMPLE TABLE PORTLET-->

                        </div>
                    </div>
                </div>
            </div>


        </section>
        <!-- /.content -->
    </aside>
    <!-- /.right-side -->
</div>
<!-- ./wrapper -->

<include file="Public:foot"/>

</body>
</html>